Remove wl_drm global #50
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This isn't used except by ancient drivers and by Xwayland as a fallback. With Xwayland this causes an issue with implicit modifiers, where Xwayland first tries to import the buffer using the dma-buf interface, then falls back to wl_drm (if it exists), which causes the compositor to crash since none of the requests are implemented in magic-mirror.
Despite magic-mirror not supporting implicit modifiers (potential TODO maybe?), just deleting wl_drm causes Xwayland to somehow do the right thing. Based on my testing, Xwayland first tries importing a buffer with implicit modifiers, and when that fails it creates another buffer with what seems to be an arbitrary modifier advertised by the server which works. Previously it would instead fallback to wl_drm
This fixes the compositor crashing on my niche set-up: magic-mirror running on an integrated GPU with applications running on my dedicated GPU which doesn't support modifiers (which is why magic-mirror can't run on it).